//
//  XGCalendarDelegate.h
//  SACalendar
//
//  Created by YaoZhaofeng on 15/4/16.
//  Copyright (c) 2015年 SyncoApp. All rights reserved.
//

#import <Foundation/Foundation.h>

@class XGCalendar;
@protocol XGCalendarDelegate <NSObject>
@optional

/**
 *  A delegate function that get called once the calendar changed to display a different month.
 *  This is caused by swiping left or right
 *
 *  @param calendar The calendar object that get changed
 *  @param month    The new month displayed
 *  @param year     The new year displayed
 */
-(void) XGCalendar:(XGCalendar*)calendar didDisplayCalendarForMonth:(int)month year:(int)year;

/**
 *  This function get called when a specific date is selected
 *
 *  @param calendar The calendar object that the selected date is on
 *  @param day      The date selected
 *  @param month    The month selected
 *  @param year     The year selected
 */
-(void) XGCalendar:(XGCalendar*)calendar didSelectDate:(int)day month:(int)month year:(int)year;
- (void) XGCalendar:(XGCalendar *)calendar didSelectDate:(NSDate *)date;


- (void)XGCalendarTableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath;

- (BOOL)XGCalendarTableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath;

- (void)XGCalendarTableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath;

- (NSString *)XGCalendarTableView:(UITableView *)tableView titleForDeleteConfirmationButtonForRowAtIndexPath:(NSIndexPath *)indexPath;
@end
